//
//  TTCustomDataSource.m
//  UADE-Mobile
//
//  Created by Marcos Damian Pianelli on 10/1/11.
//  Copyright (c) 2011 DG. All rights reserved.
//

#import "TTCustomDataSource.h"
#import "TTTableMarkItem.h"
#import "TTTableMarkItemCell.h"

#import "TTTableFileItem.h"
#import "TTTableFileItemCell.h"


@implementation TTCustomDataSource



- (UIImage*)imageForEmpty {
    return TTIMAGE(@"bundle://Three20.bundle/images/empty.png");
}

- (NSString*)titleForEmpty {
    return NSLocalizedString(@"No Files", @"");
}

- (NSString*)subtitleForEmpty {
    return NSLocalizedString(@"Don't worry there will be files soon.", @"");
}

- (UIImage*)imageForError:(NSError*)error {
    return TTIMAGE(@"bundle://Three20.bundle/images/error.png");
}

- (NSString*)subtitleForError:(NSError*)error {
    return NSLocalizedString(@"There was an error loading your friends.", @"");
}




- (Class)tableView:(UITableView*)tableView cellClassForObject:(id)object {
   
    if ([object isKindOfClass:[TTTableMarkItem class]]) {
        return [TTTableMarkItemCell class];
    }else if([object isKindOfClass:[TTTableFileItem class]]){
        return [TTTableFileItemCell class];
    }
    
    return [super tableView:tableView cellClassForObject:object];
    

}





@end
